package com.wh.bean;

import java.io.Serializable;

/**
 * Created by WH on 2016/9/17.
 */
public class TestB implements Serializable, Comparable<TestB> {

    private static final long serialVersionUID = -2872189514594810657L;

    private String name;

    private Integer order;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getOrder() {
        return order;
    }

    public void setOrder(Integer order) {
        this.order = order;
    }

    @Override
    public int compareTo(TestB o) {
        return this.order.compareTo(o.getOrder());
    }

    @Override
    public String toString() {
        return "TestB{" +
                "name='" + name + '\'' +
                ", order=" + order +
                '}';
    }
}
